package org.andy.shop.service;


import java.util.List;

import javax.annotation.PostConstruct;
import javax.annotation.Resource;

import org.andy.shop.dao.MenuMapper;
import org.andy.shop.model.Menu;
import org.springframework.stereotype.Service;


@Service
public class MenuService {
	
	@Resource
	private MenuMapper menuMapper;
	
	private List<Menu> menus;
	
	@PostConstruct
	public void init() {
		Menu menu = new Menu();
		menus = menuMapper.list(menu);
	}
	
	public List<Menu> getMenus(){
		return menus;
	}
}
